/**custom**/

@upload-prefix-cls: ~"sh-upload";

.@{upload-prefix-cls} {
  display: flex;
  input[type = "file"] {
    display: none;
  }
  &-select {
    display: inline-block;
  }
  &-drag{
    background: @upload-drag-background;
    border: 1px dashed @border-color-base;
    border-radius: @border-radius-small;
    text-align: center;
    cursor: pointer;
    overflow: hidden;
    transition: border-color @transition-time ease;
    &:hover{
      border: 1px dashed @primary-color
    }
  }
  &-dragOver{
    border: 2px dashed @primary-color
  }

  &-picture-card {
    background-color: @upload-picture-card-background;
    border: 1px dashed @upload-picture-card-border-color;
    border-radius: @upload-picture-card-border-radius;
    box-sizing: border-box;
    width: @upload-picture-card-width;
    height: @upload-picture-card-height;
    cursor: pointer;
    line-height: @upload-picture-card-line-height;
    i{
      font-size: 28px;
      color: #8c939d;
      text-align: center;
      width: 100%;
    }
    &:hover{
      border-color: @primary-color;
      color: @primary-color;
    }
  }

  &-list{
    display: flex;
    flex-wrap: wrap;
    &-file{
      position: relative;
      display: flex;
      align-items: center;
      margin: 0 10px 10px 0;
      color: @text-color;
      border-radius: @border-radius-small;
      border: 1px solid @upload-picture-card-border-color;
      .image-wrap {
        overflow: hidden;
        display: flex;
        width: @upload-picture-card-width;
        height: @upload-picture-card-height;
        img {
          align-items: center;
        }
      }
      .img-model {
        transition: all .3s;
        opacity: 0;
        position: absolute;
        text-align: center;
        left: 0;
        width: @upload-picture-card-width;
        height: @upload-picture-card-height;
        line-height: @upload-picture-card-line-height;
        background: rgba(0, 0, 0, .6);
        i {
          cursor: pointer;
          font-size: 24px;
          padding: 0 10px;
          color: @body-background;
        }
      }
      & > span{
        cursor: pointer;
        transition: color @transition-time @ease-in-out;
        i{
          display: inline-block;
          width: @font-size-small;
          height: @font-size-small;
          color: @text-color;
          text-align: center;
        }
      }
      &:hover .img-model {
        opacity: 1;
      }
    }
  }
}
